<!--海外管理-收货-->
<template>
  <div class="page-container">
    <page_breadcrumb :getKeyMethod="init_table_model" @change="change_table_model" pageOption />
    <el-form class="flex_col flex_cell" :model="form" ref="form">
      <ex_super_table_page v-bind="option" ref="SuperTablePage" :autoLoad="false">
        <template v-slot:table-top>
          <el-alert v-if="isAutomaticWarehouseArea=='Y'" :title="$tt('label_inbound_order_will_into_auto_location', { order: inboundOrderCode })" type="warning"
            :closable="false" />
        </template>
        <template v-slot:type>
          <el-form-item :label="$tt('label_receiving_type')">
            <ex_super_input :value="type" type="select" :items="typeList" i18n :disabled="typeDisabled"
              @change="changeType">
            </ex_super_input>
          </el-form-item>
        </template>



      </ex_super_table_page>
    </el-form>


    <ex_super_dialog_form ref="formDialogReceiving" :title="$tt('label_receiving_confirm')" v-bind="dialogBindReceiving"
      @afterSubmitSuccess="receivingSuccess">

    </ex_super_dialog_form>

  </div>
</template>
<script>
import superTablePageFunction from '@/mixin/super-table-page-function';
import router_params from '@/mixin/router_params';
import page_table_model_manage from '@/mixin/page_table_model_manage';


export default {
  title: 'title_standard_receiving',
  mixins: [superTablePageFunction, router_params, page_table_model_manage],
  data() {
    return {
      form: {
        receivingBoxInput: false,
        list: [],
      },
      orderEditDisabled: false,
      type: 'BOX',
      typeDisabled: false,
      receivingId: "",
      receivingCode: "",
      inboundOrderId: "",
      inboundOrderCode: "",

      isPallet: 'N',
      isAutomaticWarehouseArea: 'N',


      option: {
        search: {
          default: { inboundOrderCode: '' },
          model: [
            { slot: "type", },
            {
              label: "label_search", key: "inboundOrderCode",
              keylist: [
                { label: 'label_inbound_code', value: 'inboundOrderCode' }, { label: 'label_receiving_code', value: 'receivingCode' }
              ],
            },

          ],
        },
        actionExtra: [
          { label: 'label_receiving_confirm', attrs: { type: "primary" }, if: () => !this.orderEditDisabled, click: this.clickReceiving },
          // { label: 'label_print_inbound_code', click: this.$noFunction },
          // { label: 'label_batch_import', click: this.$noFunction },
          // { label: 'label_no_arrival_sku', attrs: { type: "danger" }, click: this.$noFunction },
        ],
        table: {
          autoPage: false, specialStyle: false,
          attrs: { 'cell-class-name': this.cellClassName, 'span-method': this.objectSpanMethod },
          url: "/wms-api/inbound/WmsInboundOverseasReceivingRpc/selectBoxDetail.json",
          urlDataHandle: this.dataHandle,
          model: this.init_table_model(),
        },
      },

      skuUrlList: [],
      dialogBindReceiving: {
        customClass: 'dialog_auto',
        submitUrl: '/wms-api/inbound/WmsInboundOverseasReceivingRpc/receiving.json',
        submitDataHandle: this.submitReceivingDataHandle,
        form: {
          itemClass: "form_item_big",
          formClass: "form_big_col2",
          inline: true,
          model: [
            { key: 'inboundOrderCode', label: 'label_inbound_code', formType: 'text', inputClass: "bold ", },
            { key: 'receivingCode', label: 'label_receiving_code', formType: 'text', inputClass: "bold ", },
            {
              key: 'planBoxNumber', label: 'label_plan_receiving_box_number', formType: 'text', inputClass: "bold ",
              formatter: (r, c, v) => v || this.$tt("data_temp_none")
            },

            { key: 'planPieceNumber', label: 'label_plan_receiving_number', formType: 'text', inputClass: "bold ", },
            { key: 'actualBoxNumber', label: 'label_actual_receiving_box_number', formType: 'text', inputClass: "bold ", },
            { key: 'actualPieceNumber', label: 'label_actual_receiving_number', formType: 'text', inputClass: "bold ", },
            {
              key: 'items', label: 'label_receiving_sku_specification', itemClass: "form_item_flex_row over_auto", inputClass: " ",
              formType: 'table', 'max-height': 500,
              model: [

                { key: 'boxNo', label: 'label_box_code', 'min-width': 120, 'show-overflow-tooltip': true, },
                { key: 'quantity', label: 'label_plan_receiving_number', 'width': 120, },
                { key: 'receivingQty', label: 'label_actual_receiving_number', 'width': 120, },
                { key: 'temporaryAreaCode', label: 'label_receiving_warehouse_area', 'min-width': 120, 'show-overflow-tooltip': true, },
                { key: 'temporaryLocationCode', label: 'label_receiving_warehouse_location', 'min-width': 120, 'show-overflow-tooltip': true, },
                { key: 'receivingUserName', label: 'label_receiving_user', 'min-width': 120, 'show-overflow-tooltip': true, },
              ]
            }
          ],
        }
      },
      rules: {
        temporaryLocationId: { type: "string", required: true, message: this.$tt('tip_can_no_empty'), },
        receivingUserId: { type: "string", required: true, message: this.$tt('tip_can_no_empty'), },

      },
    };
  },

  computed: {
    typeSku: function () {
      return this.type == 'SKU'
    },
    typeBox: function () {
      return this.type == 'BOX'
    },
    typePallet: function () {
      return this.type == 'PALLET'
    },
    Pallet: function () {
      return this.isPallet == 'Y'
    },
    typeList() {
      if (this.form.receivingBoxInput) {
        return [{ _label: 'Receiving_BOX', _value: 'BOX' }]
      }
      if (this.Pallet) {
        return [{ _label: 'Receiving_PALLET', _value: 'PALLET' },]
      } else {
        return [{ _label: 'Receiving_BOX', _value: 'BOX' }, { _label: 'Receiving_SKU', _value: 'SKU' }]
      }
    }

  },

  methods: {
    option_table_model() {
      return [
        // { key: 'boxNumber', label: 'label_box_order_number', 'width': 100, 'show-overflow-tooltip': true, },

        {
          key: 'palletNo', label: 'label_pallet_code', 'min-width': 140, 'show-overflow-tooltip': true,
          if: () => this.typePallet
        },
        { key: 'boxNo', label: 'label_box_code', 'min-width': 140, 'show-overflow-tooltip': true, },

        { key: 'skuBarcode', label: 'label_sku_code', 'min-width': 120, 'show-overflow-tooltip': true, },
        { key: 'skuName', label: 'label_sku_name', 'min-width': 120, 'show-overflow-tooltip': true, },
        {
          key: 'skuUrl', label: 'label_sku_image', slot: 'skuUrl', 'width': 120,
          render: (h, { row }) => {
            return (<ex_image_view class="page_table_image" src={row.skuUrl} lazy fit="fill" preview-src-list={this.skuUrlList} />)
          }
        },

        {
          key: 'receivingStatus', label: 'label_receiving_status', 'show-overflow-tooltip': true, 'width': 100,
          formatter: (r, c, v, i) => this.$enumShow(v, "ReceivingStatusEnum"),
        },
        {
          key: 'receivingPallet', label: 'label_actual_receiving_pallet_number', 'min-width': 180, keyShowForce: [true],
          if: () => this.typePallet,
          component: ({ row, $index, }) => {
            if (this.typePallet && !this.disabledEdit(row)) {
              return {
                type: 'input-number', class: 'w_fill',
                attrs: { min: 0, max: 1, },
                on: { change: (e) => this.changeReceivingPallet(e, row) }
              }
            } else {
              return { type: 'text', }
            }
          },
        },
        {
          key: 'receivingBoxQty', label: 'label_actual_receiving_box_number', 'min-width': 180, keyShowForce: [true],
          if: () => !this.typePallet,
          render: (h, { column, row, index }) => {
            const item = row[column.property]
            if (!this.typeBox || this.disabledEdit(row)) {
              return row.receivingBoxQty
            }
            const min = this.form.receivingBoxInput ? 1 : 0
            const max = this.form.receivingBoxInput ? 999 : 1
            return (
              <el-form-item
                prop={`list.${index}.${column.property}`}
              >
                <el-input-number
                  value={item}
                  class='w_fill'
                  min={min}
                  max={max}
                  onInput={value => {
                    this.changeReceivingBox(value, row)
                  }}
                  placeholder={column.label}
                >
                </el-input-number>
              </el-form-item>
            );
          },
        },
        { key: 'quantity', label: 'label_plan_receiving_number', 'width': 100, },
        {
          key: 'receivingQty', label: 'label_actual_receiving_number', 'min-width': 180, keyShowForce: [true],
          render: (h, { column, row, index }) => {
            if (!this.typeSku || this.disabledEdit(row)) {
              return row.receivingQty
            }
            return (
              <el-form-item
                prop={`list.${index}.${column.property}`}
              >
                <el-input-number
                  value={row.receivingQty}
                  class='w_fill'
                  min={0}
                  max={row.quantity}
                  onInput={value => {
                    this.changeReceivingQty(value, row)
                  }}
                  placeholder={column.label}
                >
                </el-input-number>
              </el-form-item>
            );
          },

        },
        {
          key: 'temporaryAreaId', label: 'label_receiving_warehouse_area', 'min-width': 180,
          keyShowForce: [true],
          renderHeader: (h, { column }) => {
            return (<div>
              <div>{this.$tt(column.label)}</div>
              <ex_dropdown_auto label='label_unified_select' size='mini' storeData option={{ label: 'labelStr', value: 'id' }}
                url='/wms-api/base/WmsBaseAreaRpc/selectAllLabel.json' onCommand={this.selectAllArea} />
            </div>)
          },
          render: (h, { row, index, column }) => {
            if (this.disabledEdit(row)) {
              return row.temporaryAreaCode
            }
            const value = row[column.property]
            return (
              <el-form-item
                prop={`list.${index}.${column.property}`}

              >
                <base_area_select value={value} class="w_fill" clearable={false}
                  onInput={e => this.$set(row, column.property, e)}
                  onChangeItem={(e) => this.changeArea(e, row)}
                />
              </el-form-item>
            )
          },


        },
        {
          key: 'temporaryLocationId', label: 'label_receiving_warehouse_location', 'min-width': 180,
          keyShowForce: [true],
          render: (h, { row, index, column }) => {
            if (this.disabledEdit(row)) {
              return row.temporaryLocationCode
            }
            const value = row[column.property]
            const rules = this.willOperate(row) ? this.rules.temporaryLocationId : null
            return (<el-form-item
              prop={`list.${index}.${column.property}`}
              rules={rules}
            ><base_location_select value={value} class="w_fill" areaId={row.temporaryAreaId} clearable={false}
              onInput={e => this.$set(row, column.property, e)}
              onChangeItem={(e) => this.changeLocation(e, row)}
              />
            </el-form-item>
            )
          },
          // component: ({ row, $index, }) => {
          //   if (!this.disabledEdit(row)) {
          //     return {
          //       type: 'base_location_select', class: 'w_fill',
          //       attrs: { areaId: row.temporaryAreaId, clearable: false, },
          //       on: { changeItem: (e) => this.changeLocation(e, row) }
          //     }
          //   } else {
          //     return { type: 'text', }
          //   }
          // },
        },
        {
          key: 'receivingUserId', label: 'label_receiving_user', 'min-width': 180,
          keyShowForce: [true],

          // renderHeader: (h, { column }) => {
          //   return (<div>
          //     <div>{this.$tt(column.label)}</div>
          //     <ex_dropdown_auto label='label_unified_select' size='mini' storeData option={{ label: 'userName', value: 'userId' }}
          //       url="/ums-api/user/UserInfoRpc/getUserDict.json" onCommand={this.selectAllUser} />
          //   </div>)
          // },
          render: (h, { row, index, column }) => {
            if (this.disabledEdit(row)) {
              return this.$formatNameCode(row.receivingUserName, row.receivingUserCode)
            }
            const value = row[column.property]
            const rules = this.willOperate(row) ? this.rules.receivingUserId : null
            return (<el-form-item
              prop={`list.${index}.${column.property}`}
              rules={rules}
            ><common_user_select value={value} class="w_fill" clearable={false}
              onInput={e => this.$set(row, column.property, e)}
              onChangeItem={(e) => this.changeUser(e, row)}
              />
            </el-form-item>)
          },
          // component: ({ row, $index, }) => {
          //   if (!this.disabledEdit(row)) {
          //     return {
          //       type: 'common_user_select', class: 'w_fill',
          //       attrs: { clearable: false, },
          //       on: { changeItem: (e) => this.changeUser(e, row) }
          //     }
          //   } else {
          //     return { type: 'text', }
          //   }
          // },
        },
        // {
        //     key: 'isAutomaticWarehouseArea', label: 'label_is_auto_location', 'width': 110, 'show-overflow-tooltip': true, 
        //     formatter: (r, c, v, i) => this.$enumShow(v, "YesOrNoEnum")
        //   },
      ]
    },
    changeType(e) {
      this.type = e
      if (this.typeBox) {
        this.$refs['SuperTablePage'].getData().forEach(row => {
          if (!this.disabledEdit(row) && row.rowspanBox) {
            if (row._linkBox.some(it => it.temporaryAreaId != row.temporaryAreaId)) {
              this.changeArea(null, row)
            } else if (row._linkBox.some(it => it.temporaryLocationId != row.temporaryLocationId)) {
              this.changeLocation(null, row)
            }
          }
        })
      }
    },

    changeReceivingPallet(e, row) {
      row._linkPallet.forEach((it) => {
        it.receivingBoxQty = e
        it.receivingPallet = e
        it.receivingQty = e ? it.quantity : 0
      })
    },
    //修改收货箱数，需要同时对对象内连接的其他箱子进行操作
    changeReceivingBox(e, row) {


      row._linkBox.forEach((it) => {
        it.receivingBoxQty = e
        it.receivingQty = e ? it.quantity : 0

      })
      if (row._linkPallet) {
        const _pallet = row._linkPallet.some(it => it.receivingQty)
        row._linkPallet.forEach(it => {
          it.receivingPallet = _pallet ? 1 : 0
        })
      }
    },
    changeReceivingQty(e, row) {
      row.receivingQty = e
      const _box = row._linkBox.some(it => it.receivingQty)
      row._linkBox.forEach(it => {
        it.receivingBoxQty = _box ? 1 : 0
      })
      if (row._linkPallet) {
        const _pallet = row._linkPallet.some(it => it.receivingQty)
        row._linkPallet.forEach(it => {
          it.receivingPallet = _pallet ? 1 : 0
        })
      }
    },
    selectAllArea(e) {
      this.$refs['SuperTablePage'].getData().forEach(row => {
        if (!this.disabledEdit(row)) {
          if (row.temporaryAreaId != e.id) {
            this.$set(row, 'temporaryAreaId', e.id)
            this.$set(row, 'temporaryAreaCode', e.code)
          }
        }
      })
    },
    //MARK:合并切换收货类型时，库区库位已选择项应该进行何种逻辑
    changeArea(e, row) {
      if (!e) e = { id: null, code: null }
      const _forList = this.typePallet ? row._linkPallet : this.typeBox ? row._linkBox : [row]
      _forList.forEach((it) => {
        this.$set(it, 'temporaryAreaId', e.id)
        this.$set(it, 'temporaryAreaCode', e.code)
      })

    },
    changeLocation(e, row) {
      if (!e) e = { id: null, code: null }
      const _forList = this.typePallet ? row._linkPallet : this.typeBox ? row._linkBox : [row]
      _forList.forEach((it) => {
        this.$set(it, 'temporaryLocationId', e.id)
        this.$set(it, 'temporaryLocationCode', e.code)
      })

    },
    changeUser(e, row) {
      if (!e) e = { userId: null, userCode: null, userName: null, }
      const _forList = [row]//this.typePallet ? row._linkPallet : row._linkBox
      _forList.forEach((it) => {
        this.$set(it, "receivingUserId", e.userId)
        this.$set(it, "receivingUserCode", e.userCode)
        this.$set(it, "receivingUserName", e.userName)
      })
    },
    init_data_default(into_params) {
      let params = into_params


      let search = params
      if (!_.isEmpty(search)) {

        this.inboundOrderCode = ""
        this.inboundOrderId = ""
        this.$refs['SuperTablePage'].setSearchData(Object.assign({}, this.$refs['SuperTablePage'].getSearchData(), search))
        let _keys = Object.keys(search)
        this.option.search.model.forEach(it => {
          if (it.keylist) {
            let _new_key = _.head(_.intersection(it.keylist.map(_k => _k.value), _keys))
            if (_new_key) it.key = _new_key
          }
        })
        this.$nextTick(() => {
          this.$refs['SuperTablePage'].loadDataForSearch()
        })

      }
    },


    selectAllUser(e) {
      this.$refs['SuperTablePage'].getData().forEach(it => {
        if (!this.disabledEdit(it)) {
          this.$set(it, 'receivingUserId', e.userId)
          this.$set(it, 'receivingUserCode', e.userCode)
          this.$set(it, 'receivingUserName', e.userName)
        }
      })
    },
    isBoxReceiving(row) {
      return row.boxReceivingStatus == 'RECEIVING_COMPLETED'
    },
    isBoxPutaway(row) {
      return row.boxPutawayStatus == 'PUTAWAY_COMPLETED'
    },
    isHasReceiving(row) {
      return row.receivingStatus == 'RECEIVING_COMPLETED'
    },
    isHasPutaway(row) {
      return row.putawayStatus == 'PUTAWAY_COMPLETED'
    },
    disabledEdit(row) {
      return this.isBoxReceiving(row) || this.isBoxPutaway(row) || this.orderEditDisabled
    },
    willOperate(row) {
      return !this.disabledEdit(row) && row.receivingQty > 0
    },
    cellClassName({ row, column, rowIndex, columnIndex }) {
      if (this.disabledEdit(row)) {
        return 'tableCell_disabled'
      } else {
        return 'tableCell_noHoverLight'
      }
    },

    objectSpanMethod({ row, column, rowIndex, columnIndex }) {
      if (['boxNumber', 'quantity_box', 'boxNo', 'receivingBoxQty',].includes(column.property)) {
        return { rowspan: row.rowspanBox, colspan: 1 }
      } else if (['receivingPallet', 'palletNo'].includes(column.property)) {
        return { rowspan: row.rowspanPallet, colspan: 1 }
      }
      if (['temporaryAreaId', 'temporaryLocationId',].includes(column.property)) {
        if (!this.typeSku) {
          return { rowspan: this.typeBox ? row.rowspanBox : row.rowspanPallet, colspan: 1 }
        }
      }

    },
    dataHandle(res) {
      if (!res.data || !res.data.inboundOrderCode) {
        this.$message.warning(this.$tt('tip_search_no_data'))
        this.form.list = []

        return []
      }

      const noBoxCode = (res.data.boxIsEmpty == 'Y' && !_.isEmpty(res.data.inboundOrderSkuList))
      const _list = noBoxCode ? res.data.inboundOrderSkuList : res.data.boxDetailList

      if (_.isEmpty(_list)) {
        this.$message.warning(this.$tt('tip_search_no_data'))
        this.form.list = []

        return []
      }
      this.receivingCode = res.data.taskCode ? res.data.taskCode : ""
      this.receivingId = res.data.taskId ? res.data.taskId : ""
      this.inboundOrderCode = res.data.inboundOrderCode
      this.inboundOrderId = res.data.inboundOrderId
      this.isPallet = res.data.isPallet

      this.isAutomaticWarehouseArea = res.data.isAutomaticWarehouseArea

      this.form.receivingBoxInput = false
      this.typeDisabled = false
      if (noBoxCode) {
        this.typeDisabled = true
        this.orderEditDisabled = _list.some(it => this.isHasReceiving(it))
        _list.forEach(it => it.boxDetailId = it.id)
        this.form.receivingBoxInput = true
        this.type = 'BOX'
      } else if (this.Pallet) {
        this.type = 'PALLET'
      } else {
        this.type = 'BOX'
      }


      _list.sort((a, b) => {
        if (this.Pallet) {
          if (a.palletNo == b.palletNo) { }
          else if (a.palletNo > b.palletNo) { return 1 }
          else if (a.palletNo < b.palletNo) { return -1 }
        }
        if (a.boxNo == b.boxNo) { return 0 }
        else if (a.boxNo > b.boxNo) { return 1 }
        else if (a.boxNo < b.boxNo) { return -1 }
      })
      this.skuUrlList = _list.map(it => it.skuUrl)
      let currentUser = this.$loginUser
      if (!currentUser) currentUser = { userId: null, userCode: null, userName: null, }
      _list.map((it, i) => {
        it.temporaryAreaId = null
        it.temporaryLocationId = null


        if (!this.disabledEdit(it)) {
          it.receivingUserId = currentUser.userId
          it.receivingUserCode = currentUser.userCode
          it.receivingUserName = currentUser.userName
        }




        it._linkBox = _list.filter(it2 => it2.boxNo == it.boxNo)
        if (it.rowspanBox == undefined) {
          it._linkBox.forEach(it2 => it2.rowspanBox = 0)
          it.rowspanBox = it._linkBox.length
        }

        if (this.Pallet) {
          it._linkPallet = _list.filter(it2 => it2.palletNo == it.palletNo)
          if (it.rowspanPallet == undefined) {
            it._linkPallet.forEach(it2 => it2.rowspanPallet = 0)
            it.rowspanPallet = it._linkPallet.length
          }
        }

        // it.quantityBox = 1
        if (this.disabledEdit(it)) {
          it.receivingBoxQty = this.isBoxReceiving(it) ? 1 : 0
          if (it._linkPallet) it.receivingPallet = it._linkPallet.some(it => this.isBoxReceiving(it)) ? 1 : 0
        } else {
          it.receivingBoxQty = 1
          it.receivingPallet = 1
          it.receivingQty = it.quantity
        }

      })
      this.form.list = _list
      this.refresh_table_visible()
      return _list
    },
    checkList(_list) {
      let checkNo = false

      _list.forEach(it => {
        if (!it.temporaryAreaId) {
          this.$set(it.error, 'temporaryAreaId', "tip_can_no_empty")
          checkNo = true
        }
        if (!it.temporaryLocationId) {
          this.$set(it.error, 'temporaryLocationId', "tip_can_no_empty")
          checkNo = true
        }
        if (!it.receivingUserId) {
          this.$set(it.error, 'receivingUserId', "tip_can_no_empty")
          checkNo = true
        }
      })
      return checkNo
    },
    clickReceiving() {

      if (_.isEmpty(this.inboundOrderCode)) {
        return this.$message.error(this.$tt('tip_please_first_search'))
      }
      this.$refs.form.validate((valid) => {
        if (valid) {
          //清除不能编辑的条目
          let _hasList = this.$refs['SuperTablePage'].getData().filter(it => !this.disabledEdit(it))
          let _list = _hasList.filter(it => it.receivingQty)
          if (this.form.receivingBoxInput) {
            _list = _hasList
          }
          let planBoxNumber = _.uniqBy(_hasList, 'boxNo').length
          let actualBoxNumber = _.uniqBy(_list, 'boxNo').length
          if (this.form.receivingBoxInput) {
            planBoxNumber = ""
            actualBoxNumber = _.head(_list).receivingBoxQty
          }

          // if (this.checkList(_list,)) return this.$message.error(this.$tt('tip_detail_check_fail'))
          //计算总sku数量，统一判断
          let _receivingQty = _.reduce(_list, (sum, it) => sum + it.receivingQty, 0)
          if (_receivingQty == 0) return this.$message.error(this.$tt('tip_receiving_content_no_empty'))

          this.$refs.formDialogReceiving.show({
            inboundOrderId: this.inboundOrderId,
            inboundOrderCode: this.inboundOrderCode,
            receivingId: this.receivingId,
            receivingCode: this.receivingCode,
            receivingType: this.type,
            receivingBoxInput: this.form.receivingBoxInput,
            planBoxNumber: planBoxNumber,
            planPieceNumber: _.reduce(_hasList, (sum, v) => sum + v.quantity, 0),
            actualBoxNumber: actualBoxNumber,
            actualPieceNumber: _receivingQty,
            items: _list,
          }, true,)
        }
      })

    },
    submitReceivingDataHandle(data) {
      let urldata = {
        inboundOrderId: data.inboundOrderId,
        receivingType: data.receivingType,
      }

      if (data.receivingBoxInput) {
        urldata.noBoxDetail = {
          receivingBoxQty: data.actualBoxNumber
        }
      }

      if (data.receivingId) urldata.receivingId = data.receivingId
      urldata.boxDetailList = data.items.map(it => {
        return {
          boxId: it.boxId,
          boxNo: it.boxNo,
          receivingType: data.receivingType,
          boxDetailId: it.boxDetailId,
          receivingQty: it.receivingQty,
          temporaryAreaId: it.temporaryAreaId,
          temporaryAreaCode: it.temporaryAreaCode,
          temporaryLocationId: it.temporaryLocationId,
          temporaryLocationCode: it.temporaryLocationCode,

          receivingUserId: it.receivingUserId,
          receivingUserCode: it.receivingUserCode,
          receivingUserName: it.receivingUserName,
        }
      })
      return urldata
    },
    receivingSuccess() {
      this.reload()
      this.$emitPage("standard>inbound_manage", "reload")
      this.$emitPage("overseas=>receiving_task", "reload")
    },

  }
};

</script>
<style></style>
